package com.yhy.wxzn.common.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * @Auther: 97354
 * @Date: 2023/10/31 11:39
 * @Description: YnEnums
 * @Version 1.0.0
 */
@Getter
public enum WcsTaskTypeEnums {
    INBOUND_T(1, "输送线入库"),
    OUTBOUND_T(2, "输送线出库"),
    INBOUND_H(3, "提升机入库"),
    OUTBOUND_H(4, "提升机出库"),
    INBOUND_S(5, "叠盘机入库"),
    OUTBOUND_S(6, "拆盘机出库"),
    INBOUND_HC(7, "提升机去往源层"),
    OUTBOUND_HC(8, "提升机去往目标层"),
    PICK(9, "拣选口"),
    ALLOCATE(10, "分拨口"),
    INBOUND_STACKER(11, "堆垛机入库"),
    OUTBOUND_STACKER(12, "堆垛机出库"),
    MOVE_STACKER(13, "堆垛机移库"),
    INBOUND_SXC(14, "四向车入库"),
    OUTBOUND_SXC(15, "四向车出库"),
    MOVE_SXC(16, "四向车移库"),
    PATH(30, "路径任务"),
    SEND_BACK(99, "退回");
    private final String desc;
    private final Integer value;

    WcsTaskTypeEnums(int value, String desc) {
        this.value = value;
        this.desc = desc;
    }
    public static WcsTaskTypeEnums ofValue(Integer target) {
        for (WcsTaskTypeEnums status : values()) {
            if (status.value == target) {
                return status;
            }
        }
        return null;
    }
}
